home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Games 1996 July
/
Amiga Games 1996 #7.iso
/
userbox
/
publicdomain
/
easycalc
/
easyrexx
/
shownegative.erex
< prev
next >
Wrap
Text File
|
1996-03-31
|
519b
|
28 lines
/* script to change all negative numbers into RED */
options results
setpalette 3 15 0 0 /* make colour 3 red */
getsheetwidth /* find out the worksheet dimensions */
maxcol = result
getsheetheight
maxrow = result
do x = 0 for maxcol+1 /* loop through every cell */
do y = 0 for maxrow+1
getcelltype x y
if result ~= "STRING" then /* skip any string cell */
do
getcellvalue x y
if result < 0 then setcolour x y 3 /* less than 0? then set the colour to red */
end
end
end